Skip to main content
Version: 3.x.x

CacheAsyncStorageType


import { CacheAsyncStorageType } from "@hyper-fetch/core"

Description

Defined in cache/cache.types.ts:49

Preview

type CacheAsyncStorageType = {
delete: (key: string) => Promise<void>;
get: <Response,Error,AdapterType>(key: string) => Promise<CacheValueType<Response, Error, AdapterType> | undefined>;
keys: () => Promise<string[] | IterableIterator<string> | string[]>;
set: <Response,Error,AdapterType>(key: string, data: CacheValueType<Response, Error, AdapterType>) => Promise<void>;
}

Structure

{
delete: (key: string) => Promise<void>;
get: (key: string) => Promise<CacheValueType<Response, Error, AdapterType> | undefined>;
keys: () => Promise<string[] | IterableIterator<string> | string[]>;
set: (key: string, data: CacheValueType<Response, Error, AdapterType>) => Promise<void>;
}